<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
	<meta http-equiv="content-type" content="text/html; charset=iso-8859-1">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="pragma" content="no-cache">
	<meta name="googlebot" content="noarchive">
	<meta name="robots" content="none">
	<meta name="author" content="jgen">
	<meta name="version" content="0.1">
	<meta name="description" content="A remote interface for Urban Terror 4.1 servers">
	<title>Remote Interface</title>
<!--
  Remote Interface (for Urban Terror)
  Author: jgen
  Date: August 2009
  [BSD Licensed]

 This interface makes use of Yahoo's User Interface Library (YUI),
 available under a BSD license from:
 http://developer.yahoo.com/yui/
-->

<!-- Individual YUI CSS files --> 
<link rel="stylesheet" type="text/css" href="resource/reset/reset_base.css">
<link rel="stylesheet" type="text/css" href="resource/skins/sam/skin.css">

<style type="text/css">
	html	{ background-color: #90CCDB; }
	body	{ margin:0; padding:0; }
	
	form { padding:0.3em; }
	
	form label {
		display:block;
		float:left;
		width:35%;
		clear:left;
	}
	fieldset,
	fieldset div {
		margin: 0.3em;
		padding: 0.5em;
		font-size:100%;
		border: 2px groove #ccc;
	}
	fieldset legend {
		padding-left: 5px;
		padding-right: 5px;
		padding-bottom:0;
		padding-top:0;
	}
	form fieldset legend.config {
		font-size: 107%;
		margin: 0.3em;
	}
	form fieldset input {
		margin: 2px;
	}

	p.error_small {
		font-size:85%; margin-left:2em;
	}
	p.error_title {
		/* OrangeRed, bold */
		font-size:107%; font-weight:bold; color:#FF4500; padding:1em; margin-bottom:1.5em;
	}
	p.about_title {
		font-size:114%; font-weight:bold; font-family:Courier; color:#000000;
	}
	p.about_version {
		font-size:85%; font-family:Courier; margin-left:2em;
	}
	p.status_ok {
		/* Green */
		font-size:107%; margin-top:1em; text-align:center; color:#009900;
	}
	p.status_err {
		/* OrangeRed  */
		font-size:107%; margin-top:1em; text-align:center; color:#FF4500;
	}
	table.server_info { border-style: none; border: 0px; width: 350px; text-align: left; padding: 0px; }
	table.server_info td { border: 0px; padding: 0.5em; }
	table.server_info td.name { font-weight: bold; }

	div.search_pager {
		margin-top: 0 !important;
		margin-left: 5px !important;
		margin-bottom: 5px;
		font-size: 100%;
	}
	div.search_pager select {
		font-size: 85%;
	}
	
	#mainmenubar {
		font-size: 100%;
	}

	span.small_button_font span.yui-button button {
		font-size: 77%;
		padding: 0 5px;
		min-height: 1.8em;
	}
</style>

<!-- All the required YUI libraries rolled into one file -->
<script type="text/javascript" src="resource/js/YUI_library_combo.js"></script> 

<!-- Remote Interface Main -->
<script type="text/javascript" src="remoteinterface.js"></script>

</head>

<body class="yui-skin-sam">

	<div id="about_info" title="About">
		<div class="hd">About Remote Interface</div>
		<div class="bd">
			<p class="about_title">Urban Terror 4.1 Remote Interface.</p><br>
			<p class="about_version">Version: 0.1 &nbsp;-&nbsp; July 2009</p>
			<p style="margin-left:2em;">Author: jgen</p>
		</div>
	</div>

	<div id="help_panel" title="Help">
		<div class="hd">Help</div>
		<div class="bd">
			<h3>Welcome to the Remote Interface</h3>
			<p>This web application is a front end to the RCON monitoring script.</p>
			<p>While it is still under development, most features available work fine.</p>
			<p>Please note:<br>
			You cannot change the rcon password or server configuration<br>
			Go ahead and try it, but the changes will not apply</p>
			<p>Wildcards are supported for all searches:</p>
			<p>
			<table border="0" cellpadding="4" style="margin-left:2em;">
				<tbody>
					<tr>
						<td><span style="color:#408080;font-weight:bold;font-family: Arial;font-size:16pt">*</span></td>
						<td>Matches any character, zero or more times</td>
					</tr>
					<tr>
						<td><span style="color:#408080;font-weight:bold;font-family: Arial;font-size:16pt">?</span></td>
						<td>Matches exactly one character</td>
					</tr>
				</tbody>
			</table>
			</p>
		</div>
	</div>
	
	<div id="options_panel" title="Options">
		<div class="hd">Options</div>
		<div class="bd">
			<fieldset id="option_container" class="option_buttons">
				<legend>Options</legend>
				<div>
					<input type="checkbox" id="config_colornames">
					<label for="config_colornames">Colorize Names</label><br>
					<input type="checkbox" id="config_convertduration">
					<label for="config_convertduration">Convert Duration</label><br>
				</div>
				<div>
					<input type="checkbox" id="config_showplayerids">
					<label for="config_showplayerids">Show Player IDs</label><br>
					<input type="checkbox" id="config_shownumericips">
					<label for="config_shownumericips">Show Numeric IPs</label><br>
					<input type="checkbox" id="config_showcreation">
					<label for="config_showcreation">Show Creation Date/Time</label><br>
					<label for="config_datetimeformat">Date Format</label>
					<input type="text" id="config_datetimeformat" class="small_edit_box" value="" size="10" maxlength="32" alt="Date/time format string" title="Date/time format string">
					<span id="config_applybtn" class="small_button_font"></span>
				</div>
			</fieldset>
		</div>
	</div>
	
	<div id="current_players" title="Current Players">
		<div class="hd">Current Players</div>
		<div class="bd"></div>
	</div>
	
	<div id="server_rcon_pw" title="Server RCON Password">
		<div class="hd">Server RCON Password</div>
		<div class="bd">
			<form id="srv_rcon_password" method="POST" action="interface.php">
				<input type="hidden" name="server_pw">
				<label for="srv_rcon_pw">RCON Password:</label><input type="text" maxlength="32" size="20" name="pw" id="srv_rcon_pw" alt="Server Rcon Password" title="Server Rcon Password"><br>
			</form>
		</div>
	</div>
	
	<div id="server_config">
		<div class="hd">Configure Server Settings</div>
		<div class="bd">
			<form id="srv_config" method="POST" action="interface.php" class="config">
				<fieldset>
					<legend class="config">Server Address</legend>
					<input type="hidden" name="server_config">
					<label for="srv_ip_address">IP:</label><input type="text" maxlength="18" size="18" name="ip" id="srv_ip_address" alt="Server IP Address" title="Server IP Address"><br>
					<label for="srv_port">Port:</label><input type="text" name="port" maxlength="8" size="10" id="srv_port" alt="Server Port - Default is 27960" title="Server Port - Default is 27960">
				</fieldset>
				<fieldset>
					<legend class="config">Timeout Configuration</legend>
					<label for="srv_timeout">Delay time:</label><input type="text" name="timeout_delay" maxlength="4" size="5" id="srv_timeout" alt="How long to wait for a response from the server" title="How long to wait for a response from the server"><br>
					<label for="srv_timeout_wait">Wait time:</label><input type="text" name="timeout_wait" maxlength="4" size="5" id="srv_timeout_wait" alt="How long to wait after a timeout occurs" title="How long to wait after a timeout occurs"><br>
				</fieldset>
			</form>
		</div>	
	</div>
	
	<div id="search_name" title="Search by Name">
		<div class="hd">Search By Name</div>
		<div class="bd">
			<form id="search_by_name" method="POST" action="interface.php">
				<input type="hidden" name="search_name">
				<label for="search_name_text">Player Name:</label><input type="text" maxlength="32" size="28" name="name_text" id="search_name_text" alt="Player name" title="Player name"> 
			</form>
		</div>
	</div>

	<div id="search_ip" title="Search by IP">
		<div class="hd">Search By IP</div>
		<div class="bd">
			<form id="search_by_ip" method="POST" action="interface.php">
				<input type="hidden" name="search_ip">
				<label for="search_ip_text">IP Address:</label><input type="text" maxlength="18" size="18" name="ip_text" id="search_ip_text" alt="Player IP Address" title="Player IP Address">
			</form>
		</div>
	</div>

	<div id="search_results_container"></div>

</body>
</html>
